Such a cocking device is known from DE 42 23 498 C2. There, a cocking slider for the cocking and uncocking of a striker spring, which can be displaced between a rear uncocking position and a front cocking position, is located on a breech housing of a rifle. The cocking slider has an upper slider part, which projects upward from the breech housing, and a lower catch part with a catch, which is located in the breech housing. The catch of the cocking slider is intended to mesh with a mating catch, which is located firmly on the breech housing, to hold the cocking slider in the front cocking position. With this known cocking device, the cocking slider for the cocking of the striker spring on the upper slider part can be pushed forward and meshes into the corresponding mating catch on the breech housing, in the front cocking position, with its catch, provided on the rear end of the catch part. By pressing on the rear end of the slider part, it is possible to press out the catch from the mating catch, wherein the cocking slider again arrives at its rear uncocked position, with the uncocking of the striker spring.